/*******************************************
 *                                         *
 *******************************************/

#ifndef TEXT_H
#define TEXT_H

#define MAX_TEXT_WIDTH  640
#define MAX_TEXT_HEIGHT 480

//Link DLL
#pragma comment (lib, "d3d9.lib")

//Include DirectX Headers
#include <d3d9.h>
#include "..\Helpers.h"

namespace DirectXFramework
{
	namespace Graphics
	{
		class Text
		{
			public:
				Text (void);
				Text (LPDIRECT3DDEVICE9 DrawDevice, UINT TextSize, BOOL Italic, LPCWSTR Font);
				~Text (void);

				BOOL Init (LPDIRECT3DDEVICE9 DrawDevice, UINT TextSize, BOOL Italic, LPCWSTR Font);
				void Draw (void);

				void SetFormat (DWORD FormatFlags);
				void SetText (LPCSTR DisplayText);
				void SetColor (DWORD TextColor);
				void SetLocation (LONG X, LONG Y);

			private:
				LPD3DXFONT TextFont;
				LPD3DXSPRITE TextSprite;
				LPCSTR TextString;
				UINT Size;
				DWORD Format;
				DWORD Color;
				RECT TextBox;
		};

		typedef Text* LPTEXT;
	};
};

#endif